<#include "/common/pagerForm.html">
<form rel="pagerForm" method="post" action="${rc.getContextPath()}/manage/material/componentLookUp?lookupType=radio" onsubmit="return  dwzSearch(this, 'dialog');">
    <div class="pageHeader">
        <div class="searchBar">
            <ul class="searchContent">
                <li><label id="materialCode" ><@label key="materialCode.C,colon">物料编号：</@label></label> <input type="text" name="materialCode" value="${condition.materialCode!''}" /></li>
                <li><label id="materialText" ><@label key="materialText.C,colon">物料描述：</@label></label> <input type="text" name="materialText" value="${condition.materialText!''}" /></li>
            </ul>
            <ul  class="searchContent">    
                <li><label><@label key="materialType.C,colon">物料类型：</@label></label> 
                <select name="materialTypeCode">
                        <option value=""><@label key="all.C">所有</@label></option> <#list materialTypes as type>
                        <option value="${type.materialTypeCode}"<#if condition.materialTypeCode?? && condition.materialTypeCode == type.materialTypeCode> selected="selected"</#if>>${type.materialTypeCode}-${type.typeText}</option> </#list>
                </select>
                </li>
                <li style="float:left">
                    <div class="buttonActive">
                        <div class="buttonContent">
                            <button type="submit"><@label key="query.B">查询</@label></button>
                        </div>
                    </div>
                </li>

            </ul>
        </div>
    </div>
</form>

<div class="pageContent">
    <table class="table" width="100%" layoutH="138">
        <thead>
            <tr>
                <th width="100"><@label key="materialCode.C">物料编号</@label></th>
                <th width="100"><@label key="materialText.C">物料描述</@label></th>
                <th width="100"><@label key="materialTypeCode.C">物料类型编号</@label></th>
                <th width="100"><@label key="materialTypeText.C">物料类型描述</@label></th>
                <th width="80"><@label key="selected_first.C">请选择</@label></th>
            </tr>
        </thead>
        <tbody>
            <#if page??><#if (page.data?size>0)> <#list page.data as material>
            <tr target="material_code" rel="${material.materialCode!''}">
                <td>${material.materialCode!''}</td>
                <td>${material.materialText!''}</td>
                <td>${material.materialTypeCode!''}</td>
                <td>${material.materialTypeText!''}</td>
                <td><a class="btnSelect bringBack" value="{materialCode:'${material.materialCode!''}', materialText:'<@json_escape>${material.materialText!''}</@json_escape>',materialSpec:'${material.materialspec!''}'}" ><@label key="select.B">选择</@label></a></td>        
                
            </tr>
            </#list> <#else>
            <tr target="material_code">
                <td colspan="5" class="noData">======<@label key="noListData.C">列表无数据</@label>=====</font>
                </td>
            </tr>
            </#if> <#else>
            <tr target="material_code">
                <td colspan="5" class="noData">======<@label key="noListData.C">列表无数据</@label>=====</font>
                </td>
            </tr>
            </#if>
        </tbody>
    </table>
    <#include "/common/dialogPanelBar.html">
</div>